package club.ruanx.spider.repository;

import club.ruanx.spider.entity.DoubanMovie;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.mongodb.repository.MongoRepository;

/**
 * @author 阮胜
 * @date 2018/11/26 14:30
 */
public interface DoubanMovieRepository extends MongoRepository<DoubanMovie, String> {
    /**
     * 分页查询未同步的爬虫数据
     *
     * @param synchronization 是否已经同步过
     * @param pageable        分页参数
     * @return
     */
    Page<DoubanMovie> findAllBySynchronization(Boolean synchronization, Pageable pageable);
}
